print inline output in python

46

# Python 3 code for printing
# on the same line printing
# geeks and geeksforgeeks
# in the same line
 
print("geeks", end =" ")
print("geeksforgeeks")
 
# array
a = [1, 2, 3, 4]
 
# printing a element in same
# line
for i in range(4):
    print(a[i], end =" ")

Comments

Submit
0 Comments